#!/bin/sh

# Purpose			: Shell script tests Validation of word and numeric arguments in shell
#					  Double brackets indicate the bash-specific conditional construct that implements the regex matching operator 
#					  http://www.gnu.org/software/bash/manual/bashref.html#Conditional-Constructs
# Date/Time         : Wed Mar 14 11:41:22 IST 2012
# Modification Date :

if [ ! $# -eq 1 ]; then
	echo "Error: wrong Parameters"
	exit 1
fi


if [[ $1 =~ ^[A-Za-z]+$ ]]; then
	echo "$1: Word"
elif [[ $1 =~ ^[0-9]+$ ]]; then
	echo "$1: Number"
else
	echo "$1: Invalid Parameter"
fi
